#include <iostream>
#include <string>
#include <vector>
using namespace std;

class Util
{
public:
    static bool StringSplit(const string& inStr, const string& sep, vector<string>* result)
    {
        size_t start = 0;
        while (start < inStr.size())
        {
            auto pos = inStr.find(sep, start);
            if (pos == string::npos) break;
            result->push_back(inStr.substr(start, pos));
            start = pos + sep.size();
        }
        if (start < inStr.size()) result->push_back(inStr.substr(start));
        return true;
    }

    static int toInt(const string& s)
    {
        return atoi(s.c_str());
    }
};